﻿using System;
using System.CodeDom.Compiler;
using System.Diagnostics;
using Google.Protobuf;
using Google.Protobuf.Collections;
using Google.Protobuf.Reflection;

namespace EggLink.DanhengServer.Proto
{
	// Token: 0x0200004F RID: 79
	[DebuggerDisplay("{ToString(),nq}")]
	public sealed class AetherAvatarInfo : IMessage<AetherAvatarInfo>, IMessage, IEquatable<AetherAvatarInfo>, IDeepCloneable<AetherAvatarInfo>, IBufferMessage
	{
		// Token: 0x170000FA RID: 250
		// (get) Token: 0x06000378 RID: 888 RVA: 0x0000B2E3 File Offset: 0x000094E3
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageParser<AetherAvatarInfo> Parser
		{
			get
			{
				return AetherAvatarInfo._parser;
			}
		}

		// Token: 0x170000FB RID: 251
		// (get) Token: 0x06000379 RID: 889 RVA: 0x0000B2EA File Offset: 0x000094EA
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public static MessageDescriptor Descriptor
		{
			get
			{
				return AetherAvatarInfoReflection.Descriptor.MessageTypes[0];
			}
		}

		// Token: 0x170000FC RID: 252
		// (get) Token: 0x0600037A RID: 890 RVA: 0x0000B2FC File Offset: 0x000094FC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		MessageDescriptor IMessage.Descriptor
		{
			get
			{
				return AetherAvatarInfo.Descriptor;
			}
		}

		// Token: 0x0600037B RID: 891 RVA: 0x0000B303 File Offset: 0x00009503
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AetherAvatarInfo()
		{
		}

		// Token: 0x0600037C RID: 892 RVA: 0x0000B318 File Offset: 0x00009518
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AetherAvatarInfo(AetherAvatarInfo other) : this()
		{
			this.id_ = other.id_;
			this.index_ = other.index_;
			this.promotion_ = other.promotion_;
			this.passiveSkill_ = other.passiveSkill_.Clone();
			this.type_ = other.type_;
			this.spBar_ = ((other.spBar_ != null) ? other.spBar_.Clone() : null);
			this._unknownFields = UnknownFieldSet.Clone(other._unknownFields);
		}

		// Token: 0x0600037D RID: 893 RVA: 0x0000B399 File Offset: 0x00009599
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AetherAvatarInfo Clone()
		{
			return new AetherAvatarInfo(this);
		}

		// Token: 0x170000FD RID: 253
		// (get) Token: 0x0600037E RID: 894 RVA: 0x0000B3A1 File Offset: 0x000095A1
		// (set) Token: 0x0600037F RID: 895 RVA: 0x0000B3A9 File Offset: 0x000095A9
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Id
		{
			get
			{
				return this.id_;
			}
			set
			{
				this.id_ = value;
			}
		}

		// Token: 0x170000FE RID: 254
		// (get) Token: 0x06000380 RID: 896 RVA: 0x0000B3B2 File Offset: 0x000095B2
		// (set) Token: 0x06000381 RID: 897 RVA: 0x0000B3BA File Offset: 0x000095BA
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Index
		{
			get
			{
				return this.index_;
			}
			set
			{
				this.index_ = value;
			}
		}

		// Token: 0x170000FF RID: 255
		// (get) Token: 0x06000382 RID: 898 RVA: 0x0000B3C3 File Offset: 0x000095C3
		// (set) Token: 0x06000383 RID: 899 RVA: 0x0000B3CB File Offset: 0x000095CB
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public uint Promotion
		{
			get
			{
				return this.promotion_;
			}
			set
			{
				this.promotion_ = value;
			}
		}

		// Token: 0x17000100 RID: 256
		// (get) Token: 0x06000384 RID: 900 RVA: 0x0000B3D4 File Offset: 0x000095D4
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public RepeatedField<uint> PassiveSkill
		{
			get
			{
				return this.passiveSkill_;
			}
		}

		// Token: 0x17000101 RID: 257
		// (get) Token: 0x06000385 RID: 901 RVA: 0x0000B3DC File Offset: 0x000095DC
		// (set) Token: 0x06000386 RID: 902 RVA: 0x0000B3E4 File Offset: 0x000095E4
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public AetherdivideSpiritLineupType Type
		{
			get
			{
				return this.type_;
			}
			set
			{
				this.type_ = value;
			}
		}

		// Token: 0x17000102 RID: 258
		// (get) Token: 0x06000387 RID: 903 RVA: 0x0000B3ED File Offset: 0x000095ED
		// (set) Token: 0x06000388 RID: 904 RVA: 0x0000B3F5 File Offset: 0x000095F5
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public SpBarInfo SpBar
		{
			get
			{
				return this.spBar_;
			}
			set
			{
				this.spBar_ = value;
			}
		}

		// Token: 0x06000389 RID: 905 RVA: 0x0000B3FE File Offset: 0x000095FE
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override bool Equals(object other)
		{
			return this.Equals(other as AetherAvatarInfo);
		}

		// Token: 0x0600038A RID: 906 RVA: 0x0000B40C File Offset: 0x0000960C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public bool Equals(AetherAvatarInfo other)
		{
			return other != null && (other == this || (this.Id == other.Id && this.Index == other.Index && this.Promotion == other.Promotion && this.passiveSkill_.Equals(other.passiveSkill_) && this.Type == other.Type && object.Equals(this.SpBar, other.SpBar) && object.Equals(this._unknownFields, other._unknownFields)));
		}

		// Token: 0x0600038B RID: 907 RVA: 0x0000B4A0 File Offset: 0x000096A0
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override int GetHashCode()
		{
			int num = 1;
			if (this.Id != 0U)
			{
				num ^= this.Id.GetHashCode();
			}
			if (this.Index != 0U)
			{
				num ^= this.Index.GetHashCode();
			}
			if (this.Promotion != 0U)
			{
				num ^= this.Promotion.GetHashCode();
			}
			num ^= this.passiveSkill_.GetHashCode();
			if (this.Type != AetherdivideSpiritLineupType.AetherdivideSpiritLineupNone)
			{
				num ^= this.Type.GetHashCode();
			}
			if (this.spBar_ != null)
			{
				num ^= this.SpBar.GetHashCode();
			}
			if (this._unknownFields != null)
			{
				num ^= this._unknownFields.GetHashCode();
			}
			return num;
		}

		// Token: 0x0600038C RID: 908 RVA: 0x0000B554 File Offset: 0x00009754
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public override string ToString()
		{
			return JsonFormatter.ToDiagnosticString(this);
		}

		// Token: 0x0600038D RID: 909 RVA: 0x0000B55C File Offset: 0x0000975C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void WriteTo(CodedOutputStream output)
		{
			output.WriteRawMessage(this);
		}

		// Token: 0x0600038E RID: 910 RVA: 0x0000B568 File Offset: 0x00009768
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalWriteTo(ref WriteContext output)
		{
			if (this.Id != 0U)
			{
				output.WriteRawTag(8);
				output.WriteUInt32(this.Id);
			}
			if (this.Index != 0U)
			{
				output.WriteRawTag(16);
				output.WriteUInt32(this.Index);
			}
			if (this.Promotion != 0U)
			{
				output.WriteRawTag(24);
				output.WriteUInt32(this.Promotion);
			}
			this.passiveSkill_.WriteTo(ref output, AetherAvatarInfo._repeated_passiveSkill_codec);
			if (this.Type != AetherdivideSpiritLineupType.AetherdivideSpiritLineupNone)
			{
				output.WriteRawTag(40);
				output.WriteEnum((int)this.Type);
			}
			if (this.spBar_ != null)
			{
				output.WriteRawTag(50);
				output.WriteMessage(this.SpBar);
			}
			if (this._unknownFields != null)
			{
				this._unknownFields.WriteTo(ref output);
			}
		}

		// Token: 0x0600038F RID: 911 RVA: 0x0000B628 File Offset: 0x00009828
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public int CalculateSize()
		{
			int num = 0;
			if (this.Id != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Id);
			}
			if (this.Index != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Index);
			}
			if (this.Promotion != 0U)
			{
				num += 1 + CodedOutputStream.ComputeUInt32Size(this.Promotion);
			}
			num += this.passiveSkill_.CalculateSize(AetherAvatarInfo._repeated_passiveSkill_codec);
			if (this.Type != AetherdivideSpiritLineupType.AetherdivideSpiritLineupNone)
			{
				num += 1 + CodedOutputStream.ComputeEnumSize((int)this.Type);
			}
			if (this.spBar_ != null)
			{
				num += 1 + CodedOutputStream.ComputeMessageSize(this.SpBar);
			}
			if (this._unknownFields != null)
			{
				num += this._unknownFields.CalculateSize();
			}
			return num;
		}

		// Token: 0x06000390 RID: 912 RVA: 0x0000B6DC File Offset: 0x000098DC
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(AetherAvatarInfo other)
		{
			if (other == null)
			{
				return;
			}
			if (other.Id != 0U)
			{
				this.Id = other.Id;
			}
			if (other.Index != 0U)
			{
				this.Index = other.Index;
			}
			if (other.Promotion != 0U)
			{
				this.Promotion = other.Promotion;
			}
			this.passiveSkill_.Add(other.passiveSkill_);
			if (other.Type != AetherdivideSpiritLineupType.AetherdivideSpiritLineupNone)
			{
				this.Type = other.Type;
			}
			if (other.spBar_ != null)
			{
				if (this.spBar_ == null)
				{
					this.SpBar = new SpBarInfo();
				}
				this.SpBar.MergeFrom(other.SpBar);
			}
			this._unknownFields = UnknownFieldSet.MergeFrom(this._unknownFields, other._unknownFields);
		}

		// Token: 0x06000391 RID: 913 RVA: 0x0000B791 File Offset: 0x00009991
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		public void MergeFrom(CodedInputStream input)
		{
			input.ReadRawMessage(this);
		}

		// Token: 0x06000392 RID: 914 RVA: 0x0000B79C File Offset: 0x0000999C
		[DebuggerNonUserCode]
		[GeneratedCode("protoc", null)]
		void IBufferMessage.InternalMergeFrom(ref ParseContext input)
		{
			uint num;
			while ((num = input.ReadTag()) != 0U)
			{
				if (num <= 24U)
				{
					if (num == 8U)
					{
						this.Id = input.ReadUInt32();
						continue;
					}
					if (num == 16U)
					{
						this.Index = input.ReadUInt32();
						continue;
					}
					if (num == 24U)
					{
						this.Promotion = input.ReadUInt32();
						continue;
					}
				}
				else if (num <= 34U)
				{
					if (num == 32U || num == 34U)
					{
						this.passiveSkill_.AddEntriesFrom(ref input, AetherAvatarInfo._repeated_passiveSkill_codec);
						continue;
					}
				}
				else
				{
					if (num == 40U)
					{
						this.Type = (AetherdivideSpiritLineupType)input.ReadEnum();
						continue;
					}
					if (num == 50U)
					{
						if (this.spBar_ == null)
						{
							this.SpBar = new SpBarInfo();
						}
						input.ReadMessage(this.SpBar);
						continue;
					}
				}
				this._unknownFields = UnknownFieldSet.MergeFieldFrom(this._unknownFields, ref input);
			}
		}

		// Token: 0x04000137 RID: 311
		private static readonly MessageParser<AetherAvatarInfo> _parser = new MessageParser<AetherAvatarInfo>(() => new AetherAvatarInfo());

		// Token: 0x04000138 RID: 312
		private UnknownFieldSet _unknownFields;

		// Token: 0x04000139 RID: 313
		public const int IdFieldNumber = 1;

		// Token: 0x0400013A RID: 314
		private uint id_;

		// Token: 0x0400013B RID: 315
		public const int IndexFieldNumber = 2;

		// Token: 0x0400013C RID: 316
		private uint index_;

		// Token: 0x0400013D RID: 317
		public const int PromotionFieldNumber = 3;

		// Token: 0x0400013E RID: 318
		private uint promotion_;

		// Token: 0x0400013F RID: 319
		public const int PassiveSkillFieldNumber = 4;

		// Token: 0x04000140 RID: 320
		private static readonly FieldCodec<uint> _repeated_passiveSkill_codec = FieldCodec.ForUInt32(34U);

		// Token: 0x04000141 RID: 321
		private readonly RepeatedField<uint> passiveSkill_ = new RepeatedField<uint>();

		// Token: 0x04000142 RID: 322
		public const int TypeFieldNumber = 5;

		// Token: 0x04000143 RID: 323
		private AetherdivideSpiritLineupType type_;

		// Token: 0x04000144 RID: 324
		public const int SpBarFieldNumber = 6;

		// Token: 0x04000145 RID: 325
		private SpBarInfo spBar_;
	}
}
